home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 3 / BBS in a box - Trilogy III.iso / Files / Prog / U-Z / ViewIt™ 2.2 Shareware / Projects / THINK C 6.0 Demos / FaceStorLC.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-09-20  |  5.5 KB  |  262 lines  |  [TEXT/KAHL]

  1. /* FaceWare 2.2 Commands & Shared Record */
  2. /* ©FaceWare 1989-93. All Rights Reserved. */
  3.  
  4. #define    DoInit       -61L
  5. #define    DoPrep    -62L
  6. /* FaceIt commands */
  7. #define    DoLoop         0L
  8. #define    DoEvnt    -51L
  9. #define    DoMenu    -52L
  10. #define    GetMsg    -55L
  11. /* ViewIt commands */
  12. #define    DoUpdt2   -53L
  13. #define    DoUnld    -63L
  14. #define    ChgCur    121L
  15. #define    PstEvt    122L
  16. #define    PopMen    123L
  17. #define    PstNot    124L
  18. #define    SetIdl    131L
  19. #define    EndIdl    132L
  20. #define    ShoAlt    153L
  21. #define    StpAlt    154L
  22. #define    NotAlt    155L
  23. #define    CtnAlt    156L
  24. #define    SetItm1   160L
  25. #define    SetItm2   161L
  26. #define    GetItm    162L
  27. #define    FixFSC    163L
  28. #define    SelFSC    164L
  29. #define    ChkMem    171L
  30. #define    NewBlk    172L
  31. #define    PrgCmd    173L
  32. #define    GetFgC    178L
  33. #define    GetBkC    179L
  34. #define    SetFgC    180L
  35. #define    SetBkC    181L
  36. #define    SetFSS    183L
  37. #define    SetPal2   185L
  38. #define    StdOpn    201L
  39. #define    StdSav    202L
  40. #define    GetRef    205L
  41. #define    SetRef    206L
  42. #define    SetTyp    208L
  43. #define    SndBhd    250L
  44. #define    GetNam    251L
  45. #define    SetNam    252L
  46. #define    MovRec    254L
  47. #define    MovAlt    255L
  48. #define    MovDlg    256L
  49. #define    MovWin    257L
  50. #define    DrgWnd    259L
  51. #define    ShoStr    261L
  52. #define    StpStr    262L
  53. #define    NotStr    263L
  54. #define    CtnStr    264L
  55. #define    GetStd    301L
  56. #define    SetStd    302L
  57. #define    SavDlg    356L
  58. #define    SavWin    357L
  59. #define    SetSub    451L
  60. #define    TrmStr    452L
  61. #define    SetPrm    453L
  62. #define    CnvStr    454L
  63. #define    FndTxt    455L
  64. #define    NumToS    471L
  65. #define    SToNum    481L
  66. #define    GetStr    491L
  67. #define    SetStr    492L
  68. #define    SrtLst    493L
  69. #define    DupLst    494L
  70. #define    AddVew  -1200L
  71. #define    NewWnd  -1201L
  72. #define    EndWnd  -1202L
  73. #define    MdlWnd  -1203L
  74. #define    SizWnd  -1204L
  75. #define MovWnd  -1205L
  76. #define    ShoWnd  -1206L
  77. #define    HidWnd  -1207L
  78. #define    GetWVC  -1208L
  79. #define    GetWnd  -1209L
  80. #define    LnkCtl  -1210L
  81. #define    GetCtl  -1211L
  82. #define    ShoCtl  -1212L
  83. #define    GetVal  -1213L
  84. #define    SetVal  -1214L
  85. #define    OvrCtl  -1215L
  86. #define    AddCtl  -1216L
  87. #define    DrwCtl  -1217L
  88. #define    ScrCtl  -1218L
  89. #define    ActCtl  -1219L
  90. #define    SelCtl  -1220L
  91. #define    DspCtl  -1221L
  92. #define    StlCtl  -1222L
  93. #define    SavCtl  -1223L
  94. #define    SavWnd  -1224L
  95. #define    SizCtl  -1225L
  96. #define    MovCtl  -1226L
  97. #define    ClrCtl  -1227L
  98. #define    SetVCod -1228L
  99. #define HlpWnd    -1229L
  100. #define HitCtl    -1230L
  101.  
  102. /* function prototypes */
  103. void PrepIt (long x, long b, long v, long r, long f);
  104. void FaceIt (void* thePtr, long m1, long m2, long m3, long m4, long m5);
  105.  
  106. /* Global FaceWare record */
  107. typedef struct FaceRec {
  108. /* program-wide info */
  109.     short            fHead[8];
  110.     GrafPtr            fOffPort;
  111.     GrafPtr            fCOffPort;
  112.     WindowPtr        fActiveWnd;
  113.     long            fActiveRec;
  114.     short            fActiveID;
  115.     short            fActiveResID;
  116.     short            fMsgCount;
  117.     long            fFlags;
  118.     Ptr                fStuff;
  119.     long            fHeapBuff;
  120.     long            fEnvFlags;
  121.     long            fSleep;
  122.     Rect            fScreenRect;
  123.     Rect            fDragRect;
  124.     long            fFrontSleep;
  125.     long            fBackSleep;
  126.     short            fFiller1;
  127.     Handle            fStdBlock;
  128.     short            fStdCount;
  129.     short            fSysEnvArr[8];
  130.     short            fApplVRef;
  131.     OSType            fCreator;
  132.     long            fRefCon;
  133.     short            fFiller2[7];
  134.     short            fCursor;
  135.     MenuHandle        fFontMenu;
  136.     MenuHandle        fSizeMenu;
  137.     MenuHandle        fStyleMenu;
  138.     MenuHandle        fColorMenu;
  139.     SignedByte        fFiller3;
  140.     SignedByte        fI1Err;
  141.     short            fI2Err;
  142.     long            fI4Err;
  143.     short            fI8Err[4];
  144.     float            fR4Err;
  145.     short            fR8Err[4];
  146.     short            fR10Err[5];
  147.     short            fR12Err[6];
  148.     short            fFiller4[125];
  149.     long            fWDEF;
  150.     long            fGlueData;
  151.     long            fWaitNextEvent;
  152.     long            fGetNewWindow;
  153.     long            fGetNewCWindow;
  154.     long            fDisposeWindow;
  155.     long            fFiller5[4];
  156.     long            fActiveWindow;
  157.     long            fSelectWindow;
  158.     long            fUpdateOther;
  159.     ProcPtr            fFiller6[9];
  160.     EventRecord        fEvent;
  161.     short            fFiller7[225];
  162. /* utility scratch variables */
  163.     short            uHead[8];
  164.     short            uI2;
  165.     long            uI4;
  166.     float            uR4;
  167.     short            uR8[4];
  168.     short            uR10[5];
  169.     short            uR12[6];
  170.     Point            uPt;
  171.     Rect            uRect;
  172.     long            uCommand;
  173.     long            uParam[4];
  174.     long            uResult;
  175.     long            uMenuID;
  176.     long            uMenuItem;
  177.     char            uString[256];
  178.     char            uName[256];
  179.     short            uRGB[3];
  180.     Style            uStyle;
  181.     SignedByte        uI1;
  182.     short            uI8[4];
  183.     MenuHandle        uMenuHdl;
  184. /* window-related info */
  185.     short            vHead[8];
  186.     short            vErr;
  187.     ProcPtr            vCDEF;
  188.     ControlHandle    vSelectCtl;
  189.     long            vSelectRec;
  190.     short            vSelectID;
  191. /* info returned by enabled items */
  192.     short            wiHit;
  193.     short            wvHit;
  194.     short            wcHit;
  195.     short            wClick;
  196.     EventRecord        wEvent;
  197. /* window info returned by GetWnd */
  198.     WindowPtr        wWindow;
  199.     short            wResID;
  200.     short            wCount;
  201.     short            wvCount;
  202.     short            wiCount;
  203. /* control info returned by GetCtl */
  204.     ControlHandle    cControl;
  205.     short            ciIndex;
  206.     short            cvIndex;
  207.     short            ccIndex;
  208.     short            cBaseID;
  209. /* info copied from "cControl" block... */
  210.     ControlHandle    cNext;
  211.     WindowPtr        cOwner;
  212.     Rect            cRect;
  213.     SignedByte        cVis;
  214.     SignedByte        cHilite;
  215.     short            cValue;
  216.     short            cMin;
  217.     short            cMax;
  218.     Handle            cInfo;
  219.     Handle            cLoData;
  220.     ProcPtr            cAction;
  221.     long            cRefCon;
  222.     char            cTitle[256];
  223. /* info copied from "cInfo" block...*/
  224.     short            cStuff[6];
  225.     long            cTmplRefCon;
  226.     Ptr                cPtr;
  227.     Handle            cHiData;
  228.     ControlHandle    cView;
  229.     Rect            cOldRect;
  230.     Rect            cClip;
  231.     Rect            cContent;
  232.     Rect            cLimit;
  233.     long            cType;
  234.     short            cVarCode;
  235.     ResType            cResType;
  236.     short            cResID;
  237.     Handle            cResHdl;
  238.     long            cPrivate;
  239.     SignedByte        cFiller;
  240.     SignedByte        cCmdKey;
  241.     short            cPnRound;
  242.     Point            cPnSize;
  243.     SignedByte        cTxJust;
  244.     Style            cTxFace;
  245.     short            cTxSize;
  246.     short            cTxFont;
  247.     short            cDataType;
  248.     SignedByte        cDataDigits;
  249.     SignedByte        cDataFormat;
  250.     short            cDataOffset;
  251.     Ptr                cDataPtr;
  252.     short            cStorType;
  253.     long            cStorPtr;
  254.     Handle            cColors;
  255.     ProcPtr            cOverride;
  256.     short            cCount;
  257.     char            cString[256];
  258. /* private debugging table */
  259.     short            xEntries;
  260.     long            xTable[40];
  261. } *FacePtr;
  262.